package org.service.provider.one.web;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("hello")
public class HelloController {
	
	@Value("${server.port}")
	private String port;

	@GetMapping("/{name}")
	public String sayHello(@PathVariable("name") String name) {
		return "hello, " + name + ", from port: " + port;
	}

}
